Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/import path colang 2 #835

Merged
merged 3 commits into from
Nov 1, 2024
Merged

Fix/import path colang 2 #835

merged 3 commits into from
Nov 1, 2024

Conversation

Pouyanpi
Copy link
Collaborator

Description

If you import nemoguardrails standard library in a Colang 2.x config _load_imported_path function fails.

WAR: export path to root of nemoguardrails as "COLANGPATH" env var.

Limitation: the standard library must be included by default, also if the user install the wheel it does not work because it needs to be set to its location in a virtual environment

Steps to reproduce:

cd ./examples/bots/abc_v2
nemoguardrails chat --config=.

Related Issue(s)

Checklist

  • I've read the CONTRIBUTING guidelines.
  • I've updated the documentation if applicable.
  • I've added tests if applicable.
  • @mentions of the person or team responsible for reviewing proposed changes.

- Add guardrails_stdlib_path to colang_path_dirs
- Improve error message for unresolved import paths
@Pouyanpi Pouyanpi merged commit cfdd335 into develop Nov 1, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants